package chabernac.android.wordraster.rastersolver;

public class LengthWordFilter implements iWordFilter {
  private final int myMinWordLength;
  private final int myMaxWordlength;
  
  

  public LengthWordFilter(int aMinWordLength, int aMaxWordlength) {
    super();
    myMinWordLength = aMinWordLength;
    myMaxWordlength = aMaxWordlength;
  }

  @Override
  public boolean isValidWord(String aWord) {
    if(aWord.length() < myMinWordLength) return false;
    if(aWord.length() > myMaxWordlength) return false;
    return true;
  }

}
